home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d12 / ptv1n4.arc / PUT.PAS < prev    next >
Pascal/Delphi Source File  |  1990-09-13  |  469b  |  17 lines

  1. { put.pas -- Transfer a string to the passive TSR's buffer }
  2. program put;
  3. uses crt, utransfer;
  4. var
  5.    s : string;       { String to transfer }
  6.    n : word;         { Number of bytes transferred }
  7. begin
  8.    write( 'Enter a string: ' );
  9.    readln( s );
  10.    n := PutBlock( @s, length( s ) + 1, 1 );  { 1 = data-type code }
  11.    if transferError <> 0 then
  12.    begin
  13.       writeln( 'ERROR: Code #', transferError );
  14.       halt( transferError )
  15.    end { if }
  16. end.
  17.